<?php

namespace ApiBundle\Controller\User;


use ApiBundle\Controller\BaseController;
use Symfony\Component\HttpFoundation\Request;

class CompanyController extends BaseController
{
    /*
     * 企业基本信息
     */
    public function companyBaseMessageAction()
    {
        $conn = $this->get("database_connection");
        if(!$this->isLogged($conn)){
            return $this->response;
        }


        $data = $conn->fetchAssoc("SELECT * FROM company WHERE id IN (SELECT company_id FROM user WHERE id = '". $this->getUserId() ."' )");

        return $this->jsonResponse(0,"操作成功",$data);
    }


}
